#include "form_shop.h"
#include "ui_form_shop.h"
#include <QDebug>
Form_Shop::Form_Shop(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::Form_Shop)
{
    ui->setupUi(this);
    ui->pushButton->setStyleSheet("QPushButton{border-image:url(:/Main/Images/Main/close.png);}QPushButton:hover{border-image:url(:/Main/Images/Main/closeon.png);}QPushButton:pressed{border-image:url(:/Main/Images/Main/close.png);}");        //设置关闭按钮样式表
    ui->label->setStyleSheet("border-image:url(:/Shop/Images/Shop/background.png)");
    ui->label_1->setStyleSheet("border-image:url(:/Data/Images/Data/jirou.png)");
    ui->label_2->setStyleSheet("border-image:url(:/Data/Images/Data/jitui.png)");
    ui->label_3->setStyleSheet("border-image:url(:/Data/Images/Data/liwu.png)");
    ui->label_4->setStyleSheet("border-image:url(:/Data/Images/Data/mianbao.png)");
    ui->label_5->setStyleSheet("border-image:url(:/Data/Images/Data/niunai.png)");
    ui->label_6->setStyleSheet("border-image:url(:/Data/Images/Data/shaizi.png)");
    ui->label_7->setStyleSheet("border-image:url(:/Data/Images/Data/xuegao.png)");
    ui->label_8->setStyleSheet("border-image:url(:/Data/Images/Data/yu.png)");
    ui->pushButton_1->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_2->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_3->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_4->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_5->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_6->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_7->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");
    ui->pushButton_8->setStyleSheet("QPushButton{border-image:url(:/Shop/Images/Shop/button_back.png);}QPushButton:hover{border-image:url(:/Shop/Images/Shop/button_back_h.png);}QPushButton:pressed{border-image:url(:/Shop/Images/Shop/button_back_p.png);}");

}

Form_Shop::~Form_Shop()
{
    delete ui;
}

void Form_Shop::on_pushButton_clicked()
{
    emit pushButton_on_clicked(19);
    this->close();      //调用关闭函数
}

void Form_Shop::on_pushButton_1_clicked()
{
    emit pushButton_on_clicked(11);
}

void Form_Shop::on_pushButton_2_clicked()
{
    emit pushButton_on_clicked(12);
}

void Form_Shop::on_pushButton_3_clicked()
{
    emit pushButton_on_clicked(13);
}

void Form_Shop::on_pushButton_4_clicked()
{
    emit pushButton_on_clicked(14);
}

void Form_Shop::on_pushButton_5_clicked()
{
    emit pushButton_on_clicked(15);
}

void Form_Shop::on_pushButton_6_clicked()
{
    emit pushButton_on_clicked(16);
}

void Form_Shop::on_pushButton_7_clicked()
{
    emit pushButton_on_clicked(17);
}

void Form_Shop::on_pushButton_8_clicked()
{
    emit pushButton_on_clicked(18);
}
